﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

public partial class teacher_index : System.Web.UI.Page
{
    public string strcr = "";
    public string userID = "";
    public string time = "";
    public string ip = "";
    public string aTimes = "";
    public string name = "";

    protected void Page_Load(object sender, EventArgs e)
    {

        if (Session["stuId"] == null)
        {
            userID = null;
            Response.Write("<script language=javascript>alert('对不起，您还没有登录！');top.location.href='../stu/login.aspx';</script>");
            Response.End();
        }
        else
        {
            userID = Session["stuId"].ToString();
            name = Session["stuName"].ToString();
            time = Session["lastTime"].ToString();
        }

        
        //aTimes = new db_actUsers().actTimes(userID).ToString();

        db_blogroll blogroll = new db_blogroll();
        DataSet ds_blogroll = blogroll.selectBlogrollALL();
        blogrollList.DataSource = ds_blogroll.Tables[0].DefaultView;
        blogrollList.DataBind();

        db_copyright cr = new db_copyright();
        DataSet dscr = cr.selectOne();
        strcr = "Copyright &copy; " + dscr.Tables[0].Rows[0]["cryear"].ToString() + " " + dscr.Tables[0].Rows[0]["owner"].ToString() + " ALL Rights Reserved<br/><a href=\"http://www.miibeian.gov.cn\" target=\"_blank\">" + dscr.Tables[0].Rows[0]["approve"].ToString() + "</a>";

    }
}